# 元组的创建
tuple_my01 = (1, 5, 6, 8, 9)
tuple_my02 = ("元组",)  # 只有一个元素，需要保留逗号,否则会认为是一个string
tuple_my03 = 1, 5, 6, 8, 9  # python默认也是一个元组
tuple_my04 = tuple(range(1, 6))
print(tuple_my04)  # 结果：(1,2,3,4,5)
# 访问元组
print(tuple_my01[1])  # 结果：5
print(tuple_my01[:3])  # 结果：(1, 5, 6)
